package com.yudi.blog.bussiness.service;

import com.yudi.blog.bussiness.dto.Blog;
import com.yudi.blog.bussiness.vo.BlogQueryVO;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;

import java.util.List;
import java.util.Map;

/**
 * @Author YuDi
 * @Date 2021/11/11 11:48
 * @Version 1.0
 */

public interface BlogService {

    Blog getBlog(Long id);

    Blog getAndConvert(Long id);

    Page listBlog(Pageable pageable, BlogQueryVO blog);

    Page listBlog(Pageable pageable, Long tagId);

    Page listBlog(Pageable pageable);

    Page<Blog> listBlog(String query, Pageable pageable);

    List<Blog> listRecommendBlogTop(Integer size);

    Map<String,List<Blog>> archiveBlog();

    Long countBlog();

    Blog save(Blog blog);

    Blog update(Long id, Blog blog);

    void delete(Long id);
}


